#pragma once

#include "unit.h"

class CBaseEnemy : public CUnit
{
private:
	CUnit* pTarget;
	float fDamage;
	float fStunTimer;
	int nAttackRange;
	float fAttackCoolDown;
	float fAttackTimer;

public:
	CUnit* GetTarget() const { return pTarget; }
	float GetDamage() const { return fDamage; }
	float GetStunTimer() const { return fStunTimer; }
	int GetAttackRange() const { return nAttackRange; }
	float GetAttackCoolDown() const { return fAttackCoolDown; }
	float GetAttackTimer() const { return fAttackTimer; }

	void SetTarget(CUnit* val) { pTarget = val; }
	void SetDamage(float val) { fDamage = val; }
	void SetStunTimer(float val) { fStunTimer = val; }
	void SetAttackRange(int val) { nAttackRange = val; }
	void SetAttackCoolDown(float val) { fAttackCoolDown = val; }
	void SetAttackTimer(float val) { fAttackTimer = val; }

	virtual void Update(float fElapsedTime) override;
	virtual void HandleCollision(const IEntity* pOther) override;

	void FindPath();
};

